package com.dtease.agent.sse.server.config;

import lombok.Getter;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

/**
* @description 服务端 Netty配置类
* @author chentl
* @class NettyProperties
* @package com.dtease.agent.sse.server.config
* @since 2025/5/14 09:08
*/
@Getter
@Component
@ConfigurationProperties(prefix = "server.netty")
public class NettyProperties {

    private int connectTimeout = 30000;
    private int readTimeout = 60;
    private int writeTimeout = 60;

    public void setConnectTimeout(int connectTimeout) {
        this.connectTimeout = connectTimeout;
    }

    public void setReadTimeout(int readTimeout) {
        this.readTimeout = readTimeout;
    }

    public void setWriteTimeout(int writeTimeout) {
        this.writeTimeout = writeTimeout;
    }
}